As with most programming languages, Kotlin supports if for branching based on a boolean condition.

You can learn more about this in:
Run Expand Edit